﻿using DailyPoetryM.Models;
using System.Linq.Expressions;

namespace DailyPoetryM.Services;

public interface IPoetryStorage
{
    bool IsInitialized { get; }

    Task InitializeAsync();

    //根据id获得一首诗词
    Task<Poetry> GetPoetryAsync(int id);


    //组合查询功能:返回一组诗词
    Task<IEnumerable<Poetry>> GetPoetriesAsync(
        Expression<Func<Poetry, bool>> where, int skip, int take);


}

